<%@ page language="java" contentType="text/html; charset=ISO-8859-1"
	pageEncoding="ISO-8859-1"%>
<%@ taglib prefix="f" uri="http://java.sun.com/jsf/core"%>
<%@ taglib prefix="h" uri="http://java.sun.com/jsf/html"%>
<%@ taglib uri="http://richfaces.org/a4j" prefix="a4j"%>
<%@ taglib prefix="rich" uri="http://richfaces.org/rich"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Sistema de contas a pagar</title>
</head>
<body>
<f:view>
	Bem vindo <h:outputText value="#{autenticador.login}" />
	<rich:tabPanel width="450">
		<rich:tab label="Fornecedores">
			<h:form id="cadastro">
				Nome: <br />
				<h:inputText id="nome" value="#{fornecedorHandler.fornecedor.nome}"
					required="true" validator="#{fornecedorHandler.validaCase}">
					<f:validateLength minimum="5" />
				</h:inputText>
				<br />
				<h:message for="nome" style="color: darkred" />
				<br />
				Descricao: <br />
				<h:inputTextarea value="#{fornecedorHandler.fornecedor.descricao}" />
				<br />
				<h:commandButton value="Salvar" action="#{fornecedorHandler.salva}" />
				<br />

			</h:form>
	
			<rich:spacer height="10" />
			<rich:separator height="1" lineType="dotted"/>
			<rich:spacer height="10" />

			<jsp:include page="lista.jsp" />
		</rich:tab>

		<rich:tab label="Contas a Pagar">
			<jsp:include page="contas.jsp" />
		</rich:tab>
	</rich:tabPanel>
</f:view>
</body>
</html>